package flc.ast.activity;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.view.View;

import flc.ast.BaseAc;
import flc.ast.R;
import flc.ast.databinding.ActivityMovieDetailBinding;
import stark.common.basic.utils.IntentUtil;

public class MovieDetailActivity extends BaseAc<ActivityMovieDetailBinding> {

    public static String url;

    @Override
    protected int onCreate() {
        return R.layout.activity_movie_detail;
    }

    @Override
    protected void initView() {
        mDataBinding.ivMovieDetailBack.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                onBackPressed();
            }
        });
        mDataBinding.ivShare.setOnClickListener(this);
        mDataBinding.webView.loadUrl(url);
    }

    @Override
    protected void onClickCallback(View v) {
        switch (v.getId()){
            case R.id.ivShare:
                IntentUtil.shareText(mContext,url);
                break;
        }
    }

    @Override
    protected void initData() {

    }
}